#{extends 'main.html' /} #{set title:'IdeaDev' /}
<head>
<script type="application/javascript">
function viewProfile(userOnPage, userCurrent){
$.getJSON('@{User.canViewProfile()}',
           {'userOnPage':document.getElementById("viewProfile1").value,
			'userCurrent':document.getElementById("viewProfile2").value,
			},function(data){
				alert(data.result);
    	});
}
</script>

</head>

<body>
	<div id="content">
		<input type="button" id="ViewProfile" value="View Profile"
			onClick="viewProfile()"> <input id="viewProfile1"
			type="hidden" value="${userOnPage}" /> <input id="viewProfile2"
			type="hidden" value="${userCurrent}" />


	</div>
	<div id="sidebar"></div>
</body>
